// Compositor
// (c) jimon game studio

#ifndef JEH_ICOMPOSITOR
#define JEH_ICOMPOSITOR

#include "jeUnknown.h"
#include "ISerialize.h"
#include "jeStl.h"

namespace je
{
	namespace scene
	{
		class ISceneManager;

		//! Compositor
		class ICompositor:public je::core::ISerialize
		{
		protected:
			ISceneManager * CurrentSceneManager;
			jeStringd CompositorName;
			s32 CurrentPriority;
		public:
			//! Constructor
			ICompositor(ISceneManager * SceneManager,const jeStringd & SetCompositorName)
				:CurrentSceneManager(SceneManager),CompositorName(SetCompositorName),CurrentPriority(0)
			{
			}

			//! Destructor
			virtual ~ICompositor()
			{
			}

			//! Set Name
			virtual void SetName(const jeStringd & NewName)
			{
				CompositorName = NewName;
			}

			//! Get Name
			virtual const jeStringd & GetName()
			{
				return CompositorName;
			}
			
			//! Set Priority
			virtual void SetPriority(s32 Priority)
			{
				CurrentPriority = Priority;
			}

			//! Get Priority
			virtual s32 GetPriority()
			{
				return CurrentPriority;
			}

			//! On Render
			virtual void OnRender()
			{
			}

			//! Serialize
			virtual void Serialize(core::ISerializeStream * SerializeStream)
			{
				JE_SS_BEGIN(Compositor)
				JE_SS(CompositorName)
				JE_SS(CurrentPriority)
				JE_SS_END(Compositor)
			}

			//! Get Compositor Type Name
			virtual jeStringc GetCompositorTypeName() = 0;
		};
	}
}

#endif
